import { createWebHistory, createRouter } from 'vue-router'
import { setupLayouts } from 'virtual:generated-layouts'
import generatedRoutes from 'virtual:generated-pages'
// console.log(generatedRoutes)
var routes = []
generatedRoutes.forEach(v => {
    routes.push(v?.meta?.layout != false ? setupLayouts([v])[0] : v)
})
// console.log(routes)
const router = createRouter({
    history: createWebHistory(),
    routes
})

export default router;